package com.coffee.sku.api.sku.result;

import lombok.Data;

import java.io.Serializable;
import java.util.Date;
import java.util.List;

@Data
public class PeriodizationSkuListResult implements Serializable {
    private Integer skuId;
    private String title;
    private String supplierName;
    private String isIntegral;
    private String isSpellOrder;
    private String isDisable;
    private String isApprove;
    private String approveRefuseReason;
    private String isEnable;
    private String periodizationIsEnable;
    private String pidPath;
    private String isCanDelete = "Y";
    private String categoryName;
    private Integer status;
    private Integer viceCount;
    private Date createTime;


    public Integer getStatus() {
        if ("W".equals(this.isApprove)) {
            this.status = 0;
        } else if ("N".equals(this.isApprove)) {
            this.status = 1;
        } else if ("Y".equals(this.isDisable)) {
            this.status = 2;
        } else if ("N".equals(this.isEnable)) {
            this.status = 3;
        } else if ("Y".equals(this.isEnable)) {
            this.status = 4;
        }
        return status;
    }
}
